/**
 * 
 */
package org.youisoft.summer.evaluator.function.interpolation;

import java.util.Collection;
import org.youisoft.summer.evaluator.InvokeException;
import org.youisoft.summer.evaluator.context.CalContext;
import org.youisoft.summer.evaluator.function.AbstractFunction;
import org.youisoft.summer.evaluator.operator.Operator;
import org.youisoft.summer.evaluator.operator.base.MapOperator;
import org.youisoft.summer.evaluator.operator.base.NumberOperator;

/**
 * @author zijiang.jl
 *
 */
public class ThresholdFunction extends AbstractFunction{
	private static final java.util.List<Class<?>> supports;
	static{
		supports=new java.util.ArrayList<Class<?>>();
		supports.add(MapOperator.class);
		supports.add(NumberOperator.class);
	}
	
	
	
	@Override
	public String getName() {
		return "threshold";
	}



	@Override
	public <C, R, P> Operator<?> doInvoke(CalContext<C, R, P> context,
			Operator<?>... operator) throws InvokeException {
		NumberOperator x=NumberOperator.class.cast(operator[0]);
	
		
		
		
		return null;
	}
	
	private Param baseLine(java.util.Map<Number, Number> map){
		Param param=new Param();
		Collection<Number> col=map.values();
		for(int i=0;i<col.size();i++){
			
			for(int j=0;j<col.size();j++){
				
			}
		}
		
		return param;
	}
	
	private class Param{
		private Number top;
		private Number middle;
		private Number buttom;
		public final Number getTop() {
			return top;
		}
		public final void setTop(Number top) {
			this.top = top;
		}
		public final Number getMiddle() {
			return middle;
		}
		public final void setMiddle(Number middle) {
			this.middle = middle;
		}
		public final Number getButtom() {
			return buttom;
		}
		public final void setButtom(Number buttom) {
			this.buttom = buttom;
		}
		
	}
	
}
